package org.dromara.system.domain.vo;

import java.util.Date;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.github.sd4324530.fastweixin.api.config.ApiConfig;
import org.dromara.system.domain.SysAccount;
import com.alibaba.excel.annotation.ExcelIgnoreUnannotated;
import com.alibaba.excel.annotation.ExcelProperty;
import org.dromara.common.excel.annotation.ExcelDictFormat;
import org.dromara.common.excel.convert.ExcelDictConvert;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.NoArgsConstructor;

import java.io.Serial;
import java.io.Serializable;
import java.util.Date;


/**
 * 账号视图对象 sys_account
 *
 * @author yilong.fu
 * @date 2024-09-14
 */
@Data
@Builder
@AllArgsConstructor
@NoArgsConstructor
@ExcelIgnoreUnannotated
@AutoMapper(target = SysAccount.class)
public class SysAccountVo implements ApiConfig, Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     *
     */
    @ExcelProperty(value = "")
    private Long accountId;

    /**
     * 名称
     */
    @ExcelProperty(value = "名称")
    private String name;

    /**
     * 微信账号
     */
    @ExcelProperty(value = "微信账号")
    private String code;

    /**
     * 账号状态：0: 停用。1: 启用
     */
    @ExcelProperty(value = "账号状态：0: 停用。1: 启用")
    private String status;

    /**
     * TOKEN
     */
    @ExcelProperty(value = "TOKEN")
    private String token;

    /**
     * 类型：1: 公众号 2: 小程序 3: 企业号
     */
    @ExcelProperty(value = "类型：1: 公众号 2: 小程序 3: 企业号")
    private String type;

    /**
     * 微信APPID
     */
    @ExcelProperty(value = "微信APPID")
    private String wxAppId;

    /**
     * 微信APP秘钥
     */
    @ExcelProperty(value = "微信APP秘钥")
    private String wxAppSecret;

    /**
     * ACCESS_TOKEN
     */
    @ExcelProperty(value = "ACCESS_TOKEN")
    private String accessToken;

    /**
     * 刷新时间
     */
    @ExcelProperty(value = "刷新时间")
    private Date refreshTime;

    /**
     * JS TICKET
     */
    @ExcelProperty(value = "JS TICKET")
    private String jsApiTicket;

    /**
     * JS刷新时间
     */
    @ExcelProperty(value = "JS刷新时间")
    private Date jsRefreshTime;

    /**
     * 微信秘钥
     */
    @ExcelProperty(value = "微信秘钥")
    private String aesKey;

    /**
     * 商户号
     */
    @ExcelProperty(value = "商户号")
    private String merchantCode;

    /**
     * 商户支付秘钥
     */
    @ExcelProperty(value = "商户支付秘钥")
    private String merchantKey;

    /**
     * 通知地址
     */
    @ExcelProperty(value = "通知地址")
    private String notifyUrl;

    /**
     * 应用编号
     */
    @ExcelProperty(value = "应用编号")
    private String appCode;


    @Override
    public String getAppid() {
        return this.getWxAppId();
    }

    @Override
    public String getSecret() {
        return this.getWxAppSecret();
    }
}
